package com.microlecture.entity;

public class CookbookStep {
    private Integer id;

    private Integer cookbookid;

    private Integer order;

    private String stepcontent;

    private String stepimg;

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Integer getCookbookid() {
        return cookbookid;
    }

    public void setCookbookid(Integer cookbookid) {
        this.cookbookid = cookbookid;
    }

    public Integer getOrder() {
        return order;
    }

    public void setOrder(Integer order) {
        this.order = order;
    }

    public String getStepcontent() {
        return stepcontent;
    }

    public void setStepcontent(String stepcontent) {
        this.stepcontent = stepcontent == null ? null : stepcontent.trim();
    }

    public String getStepimg() {
        return stepimg;
    }

    public void setStepimg(String stepimg) {
        this.stepimg = stepimg == null ? null : stepimg.trim();
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", cookbookid=").append(cookbookid);
        sb.append(", order=").append(order);
        sb.append(", stepcontent=").append(stepcontent);
        sb.append(", stepimg=").append(stepimg);
        sb.append("]");
        return sb.toString();
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        CookbookStep other = (CookbookStep) that;
        return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
            && (this.getCookbookid() == null ? other.getCookbookid() == null : this.getCookbookid().equals(other.getCookbookid()))
            && (this.getOrder() == null ? other.getOrder() == null : this.getOrder().equals(other.getOrder()))
            && (this.getStepcontent() == null ? other.getStepcontent() == null : this.getStepcontent().equals(other.getStepcontent()))
            && (this.getStepimg() == null ? other.getStepimg() == null : this.getStepimg().equals(other.getStepimg()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
        result = prime * result + ((getCookbookid() == null) ? 0 : getCookbookid().hashCode());
        result = prime * result + ((getOrder() == null) ? 0 : getOrder().hashCode());
        result = prime * result + ((getStepcontent() == null) ? 0 : getStepcontent().hashCode());
        result = prime * result + ((getStepimg() == null) ? 0 : getStepimg().hashCode());
        return result;
    }
}